class CpuPlayer extends Player{
	public constructor(n:0|1) {
		super(n)
	}

	public testRandom5Hand(){
		super.testRandom5Hand()
		for(let c of this.hand){
			c.isFront = false
		}
	}

	public chooseWeaponCard(n:number):WeaponCard[]{
		const warr = this.weapons
		const ret:WeaponCard[] = []
		
		let idxs:number[] = []
		for(let i=0;i<warr.length;i++){
			idxs.push(i)
		}
		for(let i=0;i<n;i++){
			const idx = Math.floor(Math.random()*idxs.length)
			ret.push(warr[idxs.splice(idx, 1)[0]])
		}
		return ret
	}
}

